import Vue from 'vue'
import VueRouter from 'vue-router'
// 首页
import Home from '../components/Home.vue'
// 按钮
import iButton from '../views/i-button'
// 表单
import iForm from '../views/i-form'
// 多选框
import iCheckbox from '../views/i-checkbox'
// 动态渲染
import iDisplay from '../views/i-display'
// 全局弹窗
import iAlert from '../views/i-alert'
// 表格组件
import iTableRender from '../views/i-tbale/table-render.vue'
import iTableSlot from '../views/i-tbale/table-slot.vue'
import iTableRender2 from '../views/i-tbale/table-render2.vue'
import iTableSlot2 from '../views/i-tbale/table-slot2.vue'
// 树形组件
import iTree from '../views/i-tree'

Vue.use(VueRouter)

const routes = [{
  path: '/',
  component: Home
}, {
  path: '/button',
  component: iButton
}, {
  path: '/form',
  component: iForm
}, {
  path: '/checkbox',
  component: iCheckbox
}, {
  path: '/display',
  component: iDisplay
}, {
  path: '/alert',
  component: iAlert
}, {
  path: '/table-render',
  component: iTableRender
}, {
  path: '/table-slot',
  component: iTableSlot
}, {
  path: '/table-render2',
  component: iTableRender2
}, {
  path: '/table-slot2',
  component: iTableSlot2
}, {
  path: '/tree',
  component: iTree
}]

const router = new VueRouter({
  routes
})

export default router